/*
 * posix_mq_utils.h
 *
 *  Created on: 25/12/2012
 *      Author: Julian Ovalle
 */

#ifndef POSIX_MQ_UTILS_H_
#define POSIX_MQ_UTILS_H_

//#define MQ_UTILS_DEBUG

int pmsgq_receive(int msqid, void *buf, unsigned int size,
        unsigned int* prio, unsigned int timeout_msec, unsigned int timeout_sec);

int pmsgq_send(int msqid, void * buf, unsigned int size, int prio,
        unsigned int timeout_msec, unsigned int timeout_sec);

int pmsgq_create(char* name, int maxmsg, size_t msgsize);

int pmsgq_destroy(char* name, int mqdes);

#endif /* POSIX_MQ_UTILS_H_ */
